Add ALL Methods for Users Endpoints#268
Conversation
…sers.sql baked in
- q0hectest key works for normal data, but user-management
endpoints require CWMS User Admins; l2hectest is a better
default for these tests
…ommits with that eol
…gicEngineeringCenter/cwms-python into 266-add-create-method-for-user-management
|
Requires For the integration tests to complete, they are hanging on the locations and to ensure |
…onfirm admin role
|
Tests all clear for the users endpoint (Pending that one commit below) Two points:
resolves the full key being seen |
what about this fail? FAILED tests/cda/users/users_CDA_test.py::test_get_user_403_has_friendly_message_for_missing_roles - Failed: DID NOT RAISE <class 'cwms.api.PermissionError'> |
|
|
Resolved
|
|
~Draft until~ - HydrologicEngineeringCenter/cwms-python#268 ~is~ merged. This adds the docs and methods for managing user roles (add/delete) `cwms-cli users roles` ```bash Lists the current available roles ``` `cwms-cli users roles -h` ```bash Commands: add Add one or more roles to an existing user delete Remove one or more roles from an existing user ``` ```bash Usage: cwms-cli users roles add [OPTIONS] Version: 0.3.2 Add one or more roles to an existing user Options: --user-name TEXT Existing user name. --roles TEXT Role name(s) to add. Repeat the option or pass a comma- separated list. -h, --help Show this message and exit. ``` ``` ```bash Usage: cwms-cli users roles delete [OPTIONS] Version: 0.3.2 Add one or more roles to an existing user Options: --user-name TEXT Existing user name. --roles TEXT Role name(s) to add. Repeat the option or pass a comma- separated list. -h, --help Show this message and exit. ``` --------- Co-authored-by: Eric Novotny <nov00002@umn.edu>



Created store and update methods and their tests.
Will need #267 in order for all tests to show green/complete